<?php
class AccessLogController extends CrudController
{

    public $modelName = 'AccessLog';
    public $title = 'Access Log';

    function init()
    {
        parent::init();
        $this->indexColumns = array(
            array(
                'header' => Yii::t('user', 'time'),
                'name' => 'time',
                'type' => 'raw',
                'value' => 'date("d/m/Y H:i:s",$data->time)'
            ),
            array(
                'header' => Yii::t('user', 'role'),
                'name' => 'role',
                'type' => 'raw',
                'value' => '$data->role'
            ),
            array(
                'header' => Yii::t('user', 'name'),
                'name' => 'name',
                'type' => 'raw',
                'value' => '$data->name'
            ),
            array(
                'header' => Yii::t('user', 'ip'),
                'name' => 'name',
                'type' => 'raw',
                'value' => 'long2ip($data->ip)'
            ),
        );
    }

}

/** 
 * End file AccessLogController
 */
